Conditions | 1 |
Paths | 4 |
Total Lines | 17 |
Lines | 0 |
Ratio | 0 % |
Tests | 7 |
CRAP Score | 1 |
Changes | 1 | ||
Bugs | 0 | Features | 0 |
1 | function getSimpleType(type) { |
||
10 | 1 | module.exports = (declarations, resolve) => { |
|
|
|||
11 | 34 | const exps = []; |
|
12 | |||
13 | 34 | declarations.forEach(node => { |
|
14 | 54 | const specifiers = node.specifiers || []; |
|
15 | |||
16 | 54 | specifiers.forEach(specifier => { |
|
17 | 54 | exps.push({ |
|
18 | type: getSimpleType(specifier.type), |
||
19 | name: specifier.local.name, |
||
20 | exportedName: (specifier.exported || specifier.local).name, |
||
21 | }); |
||
22 | }); |
||
23 | }); |
||
24 | |||
25 | 34 | return exps; |
|
26 | }; |
||
27 |
This check looks for parameters in functions that are not used in the function body and are not followed by other parameters which are used inside the function.